//
//  RSSParser.h
//  LiveDailyNews
//
//  Created by smu on 11-7-21.
//  Copyright 2011年 duk. All rights reserved.
//

#import <Foundation/Foundation.h>
@class RSSItem;

@interface RSSParser : NSObject <NSXMLParserDelegate>
{
    
    id parentDelegate;
    SEL onCompleteCallback;    
    BOOL loading;
    BOOL success;
    BOOL parsed;
@private
    NSString *requestUrl;
    RSSItem *currentRSSItemObject;
    NSMutableArray *currentParseBatch;
    NSMutableString *currentParsedCharacterData;
    BOOL accumulatingParsedCharacterData;
    NSMutableData *rssItemData;
    
    BOOL parseFlag;
    

}
@property (copy, readonly) NSMutableData *rssItemData;
@property (nonatomic, retain) RSSItem *currentRSSItemObject;
@property (nonatomic, retain) NSMutableArray *currentParseBatch;
@property (nonatomic, retain) NSMutableString *currentParsedCharacterData;

- (void)parse:(NSString *)url withDelegate:(id)sender onComplete:(SEL)callback;
- (NSMutableArray *)getItems;
- (void)parseResponse;
@end
